﻿using Microsoft.Owin;
using Owin;
using Microsoft.AspNet.SignalR;
using Microsoft.Owin.Cors;

[assembly: OwinStartup(typeof(Startup))]

public class Startup
{
    public void Configuration(IAppBuilder app)
    {
        app.Map("/signalr", map =>
        {
            map.UseCors(CorsOptions.AllowAll);
            var hubconfig = new HubConfiguration
            {
                EnableJSONP = true
            };
            map.RunSignalR(hubconfig);
        });
        app.MapSignalR();
    }
}